---
title: Using Model Context Protocol (MCP) with Expo
sidebar_title: MCP Server
description: A guide on integrating Model Context Protocol with Expo projects to enhance AI model capabilities.
---

import { BookOpen02Icon } from '@expo/styleguide-icons/outline/BookOpen02Icon';

import { BoxLink } from '~/ui/components/BoxLink';
import { Collapsible } from '~/ui/components/Collapsible';
import { Terminal } from '~/ui/components/Snippet';
import { Step } from '~/ui/components/Step';
import { VideoBoxLink } from '~/ui/components/VideoBoxLink';

> **info** Expo MCP Server requires an [EAS paid plan](https://expo.dev/pricing).

[Model Context Protocol (MCP)](https://modelcontextprotocol.io/) is a standard protocol that allows AI models to integrate with external data sources, providing enhanced context for more precise responses. It enables AI-assisted tools like agents to understand your development environment more deeply, allowing them to provide better assistance with your codebase.

Expo MCP Server is a remote MCP server hosted by Expo that integrates with popular AI-assisted tools such as Claude Code, Cursor, VS Code, and others, enabling them to interact directly with your Expo projects.

<VideoBoxLink
  videoId="dp9dpIgDxZQ"
  title="Introducing Expo MCP Server: for accurate, context-aware AI responses"
  description="Enhance your AI-assisted tools for building apps with Expo."
/>

## What does Expo MCP Server do?

Expo MCP Server teaches your AI-assisted tools about the Expo SDK and lets them interact with mobile simulators and the React Native DevTools. These are three examples of the tasks Expo MCP Server enhances:

**Learn about developing with Expo.** Your AI-assisted tools can fetch the latest official Expo documentation on demand and use it to reply to prompts like:

- "Add [AGENTS.md](https://agents.md/)/CLAUDE.md to my project"
- "How do I use Expo Router?"
- "Search the Expo docs for implementing deep linking"
- "What is Expo CNG?"

**Manage dependencies.** Expo MCP Server guides you toward installing our recommended packages and uses `npx expo install` to install known, compatible versions.

- "Add SQLite with basic CRUD operations"
- "Install `expo-camera` and show me how to take photos"
- "Add `expo-notifications` for push notifications"

**Automate visual verification and testing.** Multimodal AI-assisted tools can screenshot and interact with your running app in a simulator. Expo MCP Server includes local capabilities enabled by adding the `expo-mcp` package to your project's dependencies.

- "Add a blue circle view and make sure it renders correctly"
- "Add a button and tap it to verify the interaction works"
- "Add a counter button that increments on tap and verify the state updates correctly"

Your AI-assisted tools can autonomously write the code, capture screenshots to verify the UI is correct, test interactions, and fix issues they find.

The complete table of [MCP capabilities](#available-mcp-capabilities) documents the tools and prompts Expo MCP Server provides to AI-assisted tools.

## Prerequisites

Before using Expo MCP Server, ensure you have:

- An Expo account with an EAS paid plan
- An Expo project with Expo SDK 54 and the latest `expo` package version
- AI-assisted tools with remote MCP server support (Claude Code, Cursor, VS Code, and so on)

## Installation and setup

<Step label="1">

### Install Expo MCP Server

Expo MCP Server supports integration with various AI-assisted tools. Use the general settings below or expand your specific tool for detailed instructions:

- **Server type**: Streamable HTTP
- **URL**: `https://mcp.expo.dev/mcp`
- **Authentication**: OAuth

<Collapsible summary="Claude Code setup">

<Terminal cmd={['$ claude mcp add --transport http expo-mcp https://mcp.expo.dev/mcp']} />

After installation, run `/mcp` in your Claude Code session to authenticate.

</Collapsible>

<Collapsible summary="Cursor setup">

Click the following link to install the MCP server for Cursor:

<a href="cursor://anysphere.cursor-deeplink/mcp/install?name=expo-mcp&config=eyJ1cmwiOiJodHRwczovL21jcC5leHBvLmRldi9tY3AifQ%3D%3D">
  <img
    src="https://cursor.com/deeplink/mcp-install-light.svg"
    alt="Install MCP Server"
    className="hidden max-w-48 dark:block"
  />
  <img
    src="https://cursor.com/deeplink/mcp-install-dark.svg"
    alt="Install MCP Server"
    className="block max-w-48 dark:hidden"
  />
</a>

</Collapsible>

<Collapsible summary="VS Code setup">

1. Open Command Palette (<kbd>Cmd ⌘</kbd> + <kbd>Shift</kbd> + <kbd>P</kbd> or <kbd>Ctrl</kbd> + <kbd>Shift</kbd> + <kbd>P</kbd>)
2. Run **MCP: Add Server**
3. Select **HTTP**
4. Enter the server details:
   - **URL**: `https://mcp.expo.dev/mcp`
   - **Name**: expo-mcp

</Collapsible>

</Step>

<Step label="2">

### Authenticate with Expo

After installing the MCP server, you'll need to authenticate using one of two methods:

#### Access token (recommended)

Generate a **Personal access token** from your Expo account and use it during the OAuth flow.

To generate an access token, open your EAS dashboard, navigate to **Credentials** > **Access tokens** > **Personal access tokens**, and then click **Create token**.

#### Credentials

Use your Expo account username and password. In this case, the server will generate an access token automatically.

</Step>

<Step label="3">

### Set up local capabilities (Recommended)

> **info** Local capabilities are only available in **SDK 54 and later**.

For the full MCP experience with advanced features like taking screenshots from your iOS Simulator, opening DevTools, and automation capabilities, set up a local Expo development server:

<Terminal
  cmd={[
    '$ cd /path/to/your-project',
    '',
    '# Install the expo-mcp package',
    '$ npx expo install expo-mcp --dev',
    '',
    '# Ensure you are logged in to Expo CLI with the same account as the one used to',
    '# authenticate with the MCP server',
    '$ npx expo whoami || npx expo login',
    '',
    '# Start the dev server with MCP capabilities',
    '$ EXPO_UNSTABLE_MCP_SERVER=1 npx expo start',
  ]}
/>

> **important** Whenever you start or stop the development server, you need to **reconnect or restart** your MCP server connection in your AI-assisted tool to ensure the AI-assisted tool gets refreshed capabilities.

</Step>

## Server capabilities versus local capabilities

Expo MCP Server provides two types of capabilities depending on your setup:

### Server capabilities

Server capabilities are available with just the remote MCP server connection, without needing to set up a local development server. The **generate_agents_md** tool is an example of a server capability.

### Local capabilities

Local capabilities require a local Expo development server to be running and provide advanced features that interact with your local development environment:

- **Automation tools**: Take screenshots, tap views, find elements by testID
- **Development tools**: Open React Native DevTools
- **Project analysis**: Generate `expo-router` sitemap

These capabilities enable more sophisticated workflows like automated testing, visual verification, and deeper project introspection. To use local capabilities, you will need to follow the [Set up local capabilities](#set-up-local-capabilities-recommended) section above.

## Available MCP capabilities

> **info** The MCP capabilities are subject to change from the `expo-mcp` package updates or MCP server changes. The following list is a reference and may not be up to date.

### Tools

| Tool                                   | Description                                                          | Example Prompt                                      | Availability                           |
| -------------------------------------- | -------------------------------------------------------------------- | --------------------------------------------------- | -------------------------------------- |
| `learn`                                | Learn Expo how-to for a specific topic                               | "learn how to use expo-router"                      | Server                                 |
| `search_documentation`                 | Search from Expo documentation using natural language                | "search documentation for CNG"                      | Server                                 |
| `add_library`                          | Install Expo packages with `npx expo install` and show documentation | "add sqlite and basic CRUD to the app"              | Server                                 |
| `generate_claude_md`                   | Generate **CLAUDE.md** configuration files                           | "generate a CLAUDE.md for the project"              | Server (Claude Code only)              |
| `generate_agents_md`                   | Generate **AGENTS.md** files                                         | "generate an AGENTS.md file for the project"        | Server                                 |
| `expo_router_sitemap`                  | Execute and display expo-router-sitemap output                       | "check the expo-router-sitemap output"              | Local (requires `expo-router` library) |
| `open_devtools`                        | Open React Native DevTools                                           | "open devtools"                                     | Local                                  |
| `automation_tap`                       | Tap at specific screen coordinates                                   | "tap the screen at x=12, y=22"                      | Local                                  |
| `automation_take_screenshot`           | Take full device screenshots                                         | "take a screenshot and verify the blue circle view" | Local                                  |
| `automation_find_view_by_testid`       | Find and analyze views by testID                                     | "dump properties for testID 'button-123'"           | Local                                  |
| `automation_tap_by_testid`             | Tap views by testID                                                  | "click the view with testID 'button-123'"           | Local                                  |
| `automation_take_screenshot_by_testid` | Screenshot specific views by testID                                  | "screenshot the view with testID 'button-123'"      | Local                                  |

### Prompts

If your AI-assisted tool supports [MCP prompts](https://modelcontextprotocol.io/specification/2025-06-18/server/prompts), you may see additional menu options, such as [slash commands in Claude Code](https://docs.claude.com/en/docs/claude-code/mcp#use-mcp-prompts-as-slash-commands):

| Tool                  | Description                                    | Availability                           |
| --------------------- | ---------------------------------------------- | -------------------------------------- |
| `expo_router_sitemap` | Execute and display expo-router-sitemap output | Local (requires `expo-router` library) |
| `onboarding`          | Display **AGENTS.md** content to the AI        | Server                                 |

## Limitations

The current implementation has the following limitations:

- Only supports a **single development server** connection at a time
- iOS support for local capabilities is limited to simulators only (physical devices not yet supported)
- iOS support for local capabilities is only available on macOS hosts.

## Additional resources

<BoxLink
  title="Model Context Protocol Documentation"
  Icon={BookOpen02Icon}
  description="Learn more about the MCP specification and protocol details."
  href="https://modelcontextprotocol.io/"
/>
